
# Create your models here.

from google.appengine.ext import db

### Static model
class Field(db.Expando):
    fieldID = db.StringProperty()
    fieldTitle = db.StringProperty()
    fieldQuestion = db.StringProperty()
    fieldCategory = db.IntegerProperty()
    fieldNum = db.IntegerProperty()

class QuantityTitle(db.Expando):
    titleID=db.StringProperty()
    titleName=db.StringProperty()
    titleCategory=db.IntegerProperty()
    requiredPoint=db.IntegerProperty()

class QualityTitle(db.Expando):
    titleID=db.StringProperty()
    requiredPoint=db.FloatProperty()
    titleName=db.StringProperty()
    titleLevel=db.IntegerProperty()
    titleCategory=db.IntegerProperty()
    oppositeTitle=db.StringProperty()
    fortuneContent=db.TextProperty()

class LuckyItem(db.Expando):
    itemID=db.StringProperty()
    itemName=db.StringProperty()
    qnTitleID=db.StringProperty()
    qlTitleID=db.StringProperty()    


class PlayTime(db.Expando):    
    playerID = db.StringProperty()
    playDate = db.DateProperty()
    playTime = db.IntegerProperty()
    
class PlayerInfo(db.Expando):
    playerID = db.StringProperty()
    gender=db.IntegerProperty()
    evaluatedTime = db.IntegerProperty()
    totalPoint = db.IntegerProperty()
    quantityTitle = db.StringProperty()
    qualityTitle = db.StringProperty()
    categoryPoints = db.ListProperty(float)
    categoryPlayNums = db.ListProperty(int)
    friendsNum = db.IntegerProperty()
    
class RecentEvaluation(db.Expando):
    evaluaterID = db.StringProperty()
    evaluatedID = db.StringProperty()
    evaluateTime = db.DateProperty()
    fieldID = db.StringProperty()
    fieldTitle = db.StringProperty()
    rank = db.IntegerProperty()
    noCountFlag = db.IntegerProperty()
    
class EvaluatedFriends(db.Expando): 
    evaluaterID = db.StringProperty()
    evaluatedFriendsList = db.ListProperty(str)
